<template>
  <div>
    <Card dis-hover class="bgd-content">
      <div>
        <Table width="700" :loading="loading" :columns="columns" :data="data"></Table>
      </div>
    </Card>
  </div>
</template>
<script>
import { _getPosition } from '@/api/system.js'
export default {
  name: 'position',
  data () {
    return {
      loading: true,
      ruleValidate: {
        name: [
          { required: true, message: '类型不能为空'},
        ]
      },
      columns: [
        {
            title: '类型',
            key: 'name',
            width: 120,
            align: 'center'
        },
        {
            title: '描述',
            key: 'desc'
        },
      ],
      data: []
    }
  },
  methods: {
    // 获取数据
    getList () {
      this.loading = true
      _getPosition(this.form).then( res => {
        const obj = res.data.data
        // this.total = obj.total
        this.data = obj.data
        this.loading = false
      })
    }
  },
  mounted() {
    this.getList()
  },
}
</script>
